package com.cxso.example.request.wlpt;

import com.cxso.example.domain.wlpt.driver.ApiDriverAuthDomain;
import com.cxso.example.domain.wlpt.driver.ApiDriverRealAuthDomain;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;

import javax.validation.Valid;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;


@Setter
@Getter
@AllArgsConstructor
@NoArgsConstructor
@Schema(description = "创建司机")
public class ApiConsignorDriverCreateReq extends ApiBaseReq {

    @Schema(description = "司机手机号")
    @NotBlank(message = "司机手机号不能为空")
    @Pattern(regexp = "(?:0|86|\\+86)?1[3-9]\\d{9}", message = "手机号格式错误")
    private String driverPhone;

    @Schema(description = "司机基础信息")
    @Valid
    private ApiDriverRealAuthDomain driverRealAuthDomain;

    @Schema(description = "司机认证信息")
    @Valid
    private ApiDriverAuthDomain driverAuthDomain;

}
